Add poa_ prefix to returned names when return_components=True in transposition functions - #2627
Conversation
|
@kandersolar nice to see this moving! Will this be done also for Also, I guess I should address #1553 (which is being handled here #2527) on top of this right? Once you comment on my first question (and it is addressed, if I'm right) I can later review this PR, so that its merging is sped up. |
poa_ prefix to returned named when return_components=True in transposition functionspoa_ prefix to returned names when return_components=True in transposition functions
No, the idea here was to make only the breaking changes (changing returned dict key/dataframe column names), which only affect the functions that already have the
Better to keep them separate because smaller, focused PRs are easier to review, and because it means we can be sure to get the breaking changes into the next release (a .0 release) even if the enhancements aren't ready in time.
The names of actual variables in the code are not user-facing, so strictly speaking it doesn't matter if they match the docstring (or anything else). If we want to change them to have
Hopefully the above addresses this :) These two changes can be worked on independently. I do think this PR achieves the intended scope and is ready for review though. |
Co-authored-by: Cliff Hansen <cwhanse@sandia.gov>
|
I thought the discussion in #2529 indicated that this change would happen in v0.14, since its breaking? |
|
The imminent release, which was once called v0.13.2, will be v0.14.0 instead. The whatsnew will be renamed in the release PR, and I need to clean up the milestones too. |
* adapt to changed keys from pvlib perez function pvlib/pvlib-python#2627 * whatsnew * retain compatibility with older pvlib * fix mistake
|
CI is green after I retriggered everything following making a new solarfactors release (v1.6.1) with compatibility for this change. |
* ants2d and new VF code * remove some cruft * add tests for ants2d._shaded_fraction * refactoring and more tests * tests for _apply_ground_slope * tests for _apply_sky_diffuse_model * fix return shape and tests for vf_row_ground_2d_integ * fix return shape and tests for vf_row_sky_2d_integ * major docstring cleanup * standardize to "back" instead of "rear" * shape fixes, pandas out * bugfix in unshaded ground fraction * add several tests for main function * test updates * better return type logic; more get_irradiance tests * expose max_rows, more get_irradiance tests * fix issue with horizontal array and large max_rows * fix unshaded_ground_fraction for horizontal special case * fix row->ground VF edge case * switch default model from isotropic to perez * add hardcoded regression test * alphabetize module imports * docstring work * utils functions: make height and pitch optional * get infinite_sheds working again * polishing * fix output when surface angle is scalar but irrad is array * simplify numpy import * add option to return irradiance incident on ground surface * more tests for ground irradiance * one more test * use `assert_allclose`, not `assert np.isclose` * allow specifying custom row/ground subsets * lint * use `poa_` for `return_components=True` after #2627 * misc cleanup * fix squeeze bug * deprecate `npoints`, `vectorize` * fix deprecation version * lint * docstring cleanup * whatsnew entries * fix broken gallery example * add `reference` docs entry and user guide description * add test to cover untested branch * feedback from review Co-Authored-By: Cliff Hansen <5393711+cwhanse@users.noreply.github.com> * Update pvlib/bifacial/utils.py Co-authored-by: Cliff Hansen <cwhanse@sandia.gov> * adopt new description for `phi` * Update pvlib/bifacial/utils.py Co-authored-by: Cliff Hansen <cwhanse@sandia.gov> * changes from review * allow perez_driesse * add reference to utils functions * move g0, g1 to end of function signatures * fix whatsnew merge * update tests for #1867 * Apply suggestions from code review Co-authored-by: Cliff Hansen <cwhanse@sandia.gov> * clarifications from review by @cwhanse * Update pvlib/bifacial/ants2d.py Co-authored-by: Cliff Hansen <cwhanse@sandia.gov> * transfer whatsnew entries to 0.15.3 * fix bad merge * compute airmass, dni_extra as needed * clarifying comments * lint * apply suggested edit * Apply suggestions from code review Co-authored-by: Cliff Hansen <cwhanse@sandia.gov> * lint * address comment nit * Apply suggestions from code review Co-authored-by: Will Hobbs <45701090+williamhobbs@users.noreply.github.com> * update tests per review * add notes on fixed-tilt * fix bad whatsnew auto-merge * tweaks to user's guide page * changes from review * Update pvlib/bifacial/utils.py Co-authored-by: Adam R. Jensen <39184289+AdamRJensen@users.noreply.github.com> * Update pvlib/bifacial/utils.py Co-authored-by: Adam R. Jensen <39184289+AdamRJensen@users.noreply.github.com> * Update pvlib/bifacial/ants2d.py Co-authored-by: Adam R. Jensen <39184289+AdamRJensen@users.noreply.github.com> * Update pvlib/bifacial/ants2d.py Co-authored-by: Adam R. Jensen <39184289+AdamRJensen@users.noreply.github.com> * lint --------- Co-authored-by: Cliff Hansen <5393711+cwhanse@users.noreply.github.com> Co-authored-by: Cliff Hansen <cwhanse@sandia.gov> Co-authored-by: Will Hobbs <45701090+williamhobbs@users.noreply.github.com> Co-authored-by: Adam R. Jensen <39184289+AdamRJensen@users.noreply.github.com>
return_components=Truetransposition model outputs #2529[ ] Updates entries indocs/sphinx/source/referencefor API changes.docs/sphinx/source/whatsnewfor all changes. Includes link to the GitHub Issue with:issue:`num`or this Pull Request with:pull:`num`. Includes contributor name and/or GitHub username (link with:ghuser:`user`).remote-data) and Milestone are assigned to the Pull Request and linked Issue.Note that
pvfactors_timeseries(actually solarfactors under the hood) uses the old names, so the pvfactors tests are going to fail until solarfactors is updated and a new version released.